import React, { Component } from 'react';

import { Provider } from 'react-redux'
import { BrowserRouter, } from 'react-router-dom';
import Sider from './layouts/Sider.jsx';
import Header from './layouts/Header.jsx';
import Main from './layouts/Main.jsx';
// import CatchError from './components/CatchError/CatchError.jsx';
import styles from './App.module.css';
import { ConfigProvider  } from "antd";
import zhCN from 'antd/es/locale/zh_CN';
import configureStore from './stores/storesConfig';
const store = configureStore();

class App extends Component {
  render() {
    return (
      <div>
        <ConfigProvider locale={zhCN}>
          <Provider store={store}>
            <div className={styles.App}>
              <Header></Header>
              <BrowserRouter>
                <div className={styles.comtainerMain}>
                  <Sider></Sider>
                  <Main></Main>
                </div>
              </BrowserRouter>
            </div>
          </Provider>
        </ConfigProvider>
      </div>
    );
  }
}

export default App;
